﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using DataAccess;
namespace SQT.tracnghiem.Ajax.ASP.User
{
    public partial class edited_user : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            int id=int.Parse(Request.QueryString["id"]);
            string number = Request.QueryString["number"];
            string fullname = Request.QueryString["fullname"];
            string email = Request.QueryString["email"];
            string phone =Request.QueryString["phone"];
            int? city = int.Parse(Request.QueryString["city"]);
            if (city == 0)
                city = null;
            string address = Request.QueryString["address"];
            DateTime birthday = DateTime.Parse(Request.QueryString["birthday"]);
            int sex = int.Parse(Request.QueryString["sex"]);
            bool check_sex = true;
            if(sex==0)
                check_sex = false;
            new TblUserController().Update(id, number.ToUpper(), null, null, fullname, birthday, phone, null, email, address, city, null, check_sex, null, null, null, null, null, null);
        }
    }
}